package com.work.service.impl;

import com.work.bean.Student;
import com.work.dao.StudentDao;
import com.work.dao.impl.StudentDaoImpl;
import com.work.service.StudentService;

import java.util.List;

public class StudentServiceImpl implements StudentService {
    StudentDao studentDao= new StudentDaoImpl();

    public Student queryStudentById(Integer id) {
        return studentDao.queryStudentById(id)  ;
    }

    public List<Student> queryStudent() {
        return studentDao.queryStudent();
    }

    public int saveStudent(Student student) {
        return studentDao.saveStudent(student);
    }

    public int updateStudent(Student student) {
        return studentDao.updateStudent(student);
    }

    public int deleteStudent(Integer id) {
        return studentDao.deleteStudent(id);
    }


    public Student query() {
        return studentDao.query();
    }
}
